package com.zh.mediacommon.util;

import org.springframework.stereotype.Component;

import java.util.Random;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;


public class VerifyCodeUtil {
    private static String code;
    private static final Integer TIME = 5;
    public static String getCode(){
        Random random = new Random();
        StringBuilder smsCode = new StringBuilder(6);

        for (int i = 0; i < 6; i++) {
            smsCode.append(random.nextInt(10));
        }
        code=smsCode.toString();
        return smsCode.toString();
    }
}
